var working=true;
function preview(_1,_2){
if(!working){
return;
}
working=false;
var _3="",_4=document.createElement("div"),_5=document.documentElement,_6=_5.clientHeight/2+(typeof (window.pageYOffset)==="undefined"?_5.scrollTop:window.pageYOffset),_7=_5.clientWidth/2+(typeof (window.pageXOffset)==="undefined"?_5.scrollLeft:window.pageXOffset);
_4.innerHTML="<div id='fC'></div>";
_4.style.cssText="width:500px;height:350px;position:absolute;background:#eee;top:"+_6+"px;left:"+_7+"px;margin-top:-225px;-margin-top:-190px;margin-left:-284px;z-index:9999;";
document.body.appendChild(_4);
_3+="<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\"";
_3+="\t id=\"preview\" width=\"500\" height=\"350\"";
_3+="\t codebase=\"  http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab\">";
_3+=" <param name=\"movie\" value=\"  http://"+_2+"/xnapp/giftpro/card/flash/diy_view.swf\" />";
_3+=" <param name=\"quality\" value=\"high\" />";
_3+=" <param name=\"flashvars\" value=\"datUrl="+_1+"&isSwfReadyBo=true\" />";
_3+=" <param name=\"wmode\" value=\"transparent\" />";
_3+=" <param name=\"allowScriptAccess\" value=\"always\" />";
_3+=" <embed src=\"  http://"+_2+"/xnapp/giftpro/card/flash/diy_view.swf\" quality=\"high\" ";
_3+="\t width=\"500\" height=\"350\" name=\"preview\" align=\"middle\"";
_3+="\t play=\"true\" loop=\"false\" quality=\"high\" allowScriptAccess=\"always\" wmode=\"transparent\" ";
_3+="\t flashvars=\"datUrl="+_1+"&isSwfReadyBo=true\" ";
_3+="\t type=\"application/x-shockwave-flash\"";
_3+="\t pluginspage=\"  http://www.macromedia.com/go/getflashplayer\">";
_3+=" </embed>";
_3+="</object>";
_3+="<a href=\"javascript:;\" style=\"position:absolute;top:0;right:0;\" id=\"swfClose\"><img src=\"http://"+_2+"/xnapp/giftpro/img/close.png\"/></a>";
_4.innerHTML=_3;
XN.event.addEvent($("swfClose"),"click",function(){
_4.innerHTML="";
_4.parentNode.removeChild(_4);
working=true;
},false);
}
function previewForProfile(_8,_9){
if(!working){
return;
}
working=false;
var _a="",_b=document.createElement("div"),_c=document.documentElement,_d=_c.clientHeight/2+(typeof (window.pageYOffset)==="undefined"?_c.scrollTop:window.pageYOffset),_e=_c.clientWidth/2+(typeof (window.pageXOffset)==="undefined"?_c.scrollLeft:window.pageXOffset);
_b.innerHTML="<div id='fC'></div>";
_b.style.cssText="width:500px;height:350px;position:absolute;background:#eee;top:"+_d+"px;left:"+_e+"px;margin-top:-225px;-margin-top:-190px;margin-left:-284px;z-index:9999;";
document.body.appendChild(_b);
_a+="<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\"";
_a+="\t id=\"preview\" width=\"500\" height=\"350\"";
_a+="\t codebase=\"  http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab\">";
_a+=" <param name=\"movie\" value=\" "+_9+"/xnapp/giftpro/card/flash/diy_view.swf\" />";
_a+=" <param name=\"quality\" value=\"high\" />";
_a+=" <param name=\"flashvars\" value=\"datUrl="+_8+"&isSwfReadyBo=true\" />";
_a+=" <param name=\"wmode\" value=\"transparent\" />";
_a+=" <param name=\"allowScriptAccess\" value=\"always\" />";
_a+=" <embed src=\" "+_9+"/xnapp/giftpro/card/flash/diy_view.swf\" quality=\"high\" ";
_a+="\t width=\"500\" height=\"350\" name=\"preview\" align=\"middle\"";
_a+="\t play=\"true\" loop=\"false\" quality=\"high\" allowScriptAccess=\"always\" wmode=\"transparent\" ";
_a+="\t flashvars=\"datUrl="+_8+"&isSwfReadyBo=true\" ";
_a+="\t type=\"application/x-shockwave-flash\"";
_a+="\t pluginspage=\"  http://www.macromedia.com/go/getflashplayer\">";
_a+=" </embed>";
_a+="</object>";
_a+="<a href=\"javascript:;\" style=\"position:absolute;top:0;right:0;\" id=\"_swfClose\"><img src=\" "+_9+"/xnapp/giftpro/img/close.png\"/></a>";
_b.innerHTML=_a;
XN.event.addEvent($("_swfClose"),"click",function(){
_b.innerHTML="";
_b.parentNode.removeChild(_b);
working=true;
},false);
}

